import Vue from 'vue'
import App from './App'
import store from 'store/index.js'

import "@/common/iconfont.css" //全局引入iconfont

//import '@/common/map.js'// 高德地图(仅限h5使用，目前统一使用腾讯地图)

import {
	router,
	RouterMount
} from './router/index.js' //路由
Vue.use(router)

//过滤器如果过多就写在文件里到这里遍历
Vue.filter('qq', function(before) {
	return (before / 100000000).toFixed(1) + '亿'
})

Vue.filter('time', function(before) {
	const t = new Date(before)
	const year = t.getFullYear()
	const month = t.getMonth() + 1
	const date = t.getDate()
	return year + '年' + month + '月' + date + '日'
})

import loading from 'components/hevu-loading/hevu-loading.vue' //加载层组件
Vue.component('loading', loading)

Vue.config.productionTip = false

App.mpType = 'app'

const app = new Vue({
	...App,
	store
})
app.$mount()
